home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 3 / BBS in a box - Trilogy III.iso / Files / System7 tools / S / S7P Demo ƒ / S7P Help / S7P Help.rsrc / TEXT_-16000.txt < prev    next >
Encoding:
Text File  |  1992-11-17  |  4.1 KB  |  130 lines

  1. Launching & Quitting
  2. Err:=Launch(Signature;Document Name)
  3. Err:=LaunchBehind(Creator;Document)
  4. Err:=PrintDoc(Signature;Document Name)
  5. Err:=QuitApp(Signature)
  6.  
  7. Note: A launch command doesn't complete until 4D calls the
  8. event manager. In pre-3.0 versions, the procedure must either
  9. end or call ProcessAEVT to complete the launch.
  10.  
  11. Misc. Utilities
  12. Err:=BringToFront(Signature)
  13.  
  14. Note: BringToFront only requests that the application be brought
  15. to the front. It won't actually happen until 4D calls the event
  16. manager. In pre-3.0 versions, the procedure must either end or
  17. call ProcessAEVT to allow another application to be brought to
  18. the front.
  19.  
  20. Err:=FindAppName(Signature;Name)
  21. Err:=FindCreator(File Name;Creator ID)
  22. Result:=IsRunning(Creator ID)
  23. Result:=Long(TypeString)
  24. Err:=ProcessList(Visible;StringArray)
  25. Version:=S7Version(Serialization String)
  26. SetTimeout(Ticks)
  27. Result:=System7
  28. Result:=AE Process ID
  29.  
  30. AE Process ID will always return a non-zero value if you're
  31. running 4D v3.0 or later and will return 0 if you're running
  32. an earlier version.
  33.  
  34. SetTimeOut applies to all high-level scripting commands &
  35. high-level commands which send AppleEvents.
  36.  
  37. Target Addresses
  38. Err:=AddrToString(Target;ATLocation;Name;Port)
  39. Err:=DisposeAddress(Target)
  40. Err:=MakeAddress(Signature;Target)
  41. Err:=SelectAddress(Prompt;Signature;Target)
  42. Err:=StringToAddr(ATLocation;Name;Port;Target)
  43.  
  44. Scripting
  45. Err:=DoScript(Target;Command)
  46. Err:=Evaluate(Target;Command;Result)
  47. Err:=Frontier(Command;Result)
  48. Err:=QuicKeys(Macro Name)
  49.  
  50. Sending AppleEvents
  51. Err:=AESend(Target;Class;ID;Message)
  52. Err:=AESendPict(target;class;id;aPicture)
  53. Err:=SendWithReply(Target;Class;ID;message;reply)
  54.  
  55. AppleEvent Handling
  56. AllowAccess(Flag)
  57. GetAEMessage(Msg)
  58. Err:=GetAEPict(aPicture)
  59. GetAEType(theType)
  60. GetReturnAddr(Target)
  61. Err:=HandleAEVT(Class;ID;Command)
  62. Err:=IgnoreAEVT(Class;ID)
  63. ProcessAEVT [not needed in 4D v3.0]
  64.  
  65. Low Level Interface
  66. Err:=CreateAEVT(Class;ID;Addr;theEvent)
  67. Err:=DisposeDesc(desc)
  68. Err:=GetAliasParam(theEvent;theKey;aFileName)
  69. Err:=GetList(anEvent;theKey;anArray)
  70. Err:=GetLongParam(anEvent;keyWord;actualType;Value)
  71. Err:=GetPicParam(anEvent;theKey;convert;aPicture)
  72. Err:=GetRealParam(anEvent;theKey;Value)
  73. Err:=GetShortParam(anEvent;keyWord;actualType;Value)
  74. Err:=GetTextParam(anEvent;theKey;Value)
  75. ospec:=Obj(class;container;value)
  76. ospec:=ObjNamed(Class;Container;Name)
  77. ospec:=Property(Name;Container)
  78. Err:=PutAliasParam(anEvent;theKey;fileName)
  79. Err:=PutList(anEvent;key;SpecialType;anArray)
  80. Err:=PutLongParam(anEvent;key;actualType;value)
  81. Err:=PutObject(anEvent;key;anObject)
  82. Err:=PutPicParam(anEvent;theKey;convert;aPicture)
  83. Err:=PutRealParam(anEvent;key;value)
  84. Err:=PutShortParam(anEvent;key;actualType;value)
  85. Err:=PutTextParam(anEvent;key;value)
  86. Err:=SendAppleEvent(theEvent;theReply;send mode;time out)
  87. Err:=CreateAERec(theRecord)
  88. Err:=GetAERecord(anEvent;Key;theRecord)
  89. Err:=PutAERecord(anEvent;Key;theRecord)
  90. Err:=PutKeyword(anEvent;key;value)
  91. Err:=GetKeyword(anEvent;key;value)
  92.  
  93. To extract a boolean value, use GetShortParam(...;...;"bool";...)
  94. To send a list of file aliases, use PutList(...;...;"alis";...)
  95. To send a list of AE Records or object specifiers, use
  96.  PutList(...;...;"reco";....)
  97.  
  98. GetList will automatically convert a list of file aliases to a
  99. text array containing the file names or a list of AERecords,
  100. object specifiers or records to an array of long integers
  101. which represent descriptors.
  102.  
  103. Constants
  104. AlwaysInteract
  105. CanInteract
  106. NeverInteract
  107. kAENoReply
  108. kAEWaitReply
  109.  
  110. These constants can be used to specify the send mode for
  111. SendAppleEvent. Use an interaction value + a reply value.
  112.  
  113. Advanced Commands
  114. Err:=CreateXAEVT(Class;id;addr;returnID;TransID;aevt)
  115. Result:=CopyDesc(aevt)
  116. Result:=GetTransactionID(aevt)
  117. Result:=GetReturnID(aevt)
  118. Err:=GetAEInfo(Descriptor;Size;Keys;Types;Lengths)
  119. Err:=GetNthDesc(aevt,index,key,type,result)
  120. Err:=GetNthItem(aevt,index,key,type,textVar)
  121.  
  122. Use CopyDesc(0) to obtain the current event being handled.
  123.  
  124. Transaction IDs and Return IDs can be used to associate a
  125. queued reply with a specific event that was sent.
  126.  
  127. GetAEInfo, GetNthDesc, and GetNthItem can be used to
  128. examine an AppleEvent to determine what keywords are
  129. present.
  130.